const {spawn} = require('child_process');

var showChild=spawn('node',['exec-child.js'])

//spawn以流的方式进行数据的接收
showChild.stdout.on('data',(chunk)=>{
    console.log(chunk.toString('utf-8'))
})